# tool chain for blueprint
SET(CMAKE_SYSTEM_PROCESSOR "P5p")
SET(QMC_ENV "IBMP5p" CACHE STRING "Setting envirnoments for IBM P5+")

#SET_PROPERTY(GLOBAL PROPERTY TARGET_SUPPORTS_SHARED_LIBS FALSE)

set(CMAKE_C_COMPILER  /usr/vacpp/bin/xlc)
set(CMAKE_CXX_COMPILER /opt/freeware/bin/g++)

SET(GNU_COMMON_OPTS "-v -g -O3 -ffast-math -ftemplate-depth-60 -Drestrict=__restrict__ -funroll-all-loops -finline-limit=1000 -Wno-deprecated")
#SET(GNU_COMMON_OPTS "-v -g -O3 -ftemplate-depth-60 -Drestrict=__restrict__ -funroll-all-loops -Wno-deprecated")
#SET(CMAKE_CXX_FLAGS "${GNU_COMMON_OPTS} -mcpu=power5+ -fomit-frame-pointer -fopenmp")
SET(CMAKE_CXX_FLAGS "${GNU_COMMON_OPTS} -mcpu=power5+ -fomit-frame-pointer")

SET(AIX_BIT_FLAGS "")
SET(AIX_CXX_COMMON_FLAGS "-qrtti=dyna -qnoeh -qsuppress=1540-1090 ")
#SET(AIX_OPT_FLAGS "-g -O3 -Q -qmaxmem=-1 -qinline -qlargepage -qprefetch -qstrict -qhot -qkeyword=restrict")
SET(AIX_OPT_FLAGS "-g -O3 -qlargepage -qprefetch -qstrict -qhot -qkeyword=restrict")
SET(AIX_C_FLAGS "-qlanglvl=stdc99")
#SET(CMAKE_C_FLAGS "-O3 -Drestrict=__restrict__ -funroll-all-loops   -finline-limit=1000 -std=gnu99 -fomit-frame-pointer ")
SET(CMAKE_C_FLAGS "-O3 -Drestrict=__restrict__ -funroll-all-loops   -finline-limit=1000 -fomit-frame-pointer ")
SET(CMAKE_C_FLAGS 
"${CMAKE_C_FLAGS} ${AIX_ARCH_FLAGS} ${AIX_OPT_FLAGS} ${AIX_C_FLAGS}")

set(CMAKE_FIND_ROOT_PATH
    /opt/freeware
    /u/home/ac/jnkim/src/boost/src
    /u/home/ac/jnkim/build/32
    /usr/lpp/xlf
     )

set(EINSPLINE_HOME "/u/home/ac/jnkim/src/einspline" CACHE STRING "Einspline source directory")
